This notebook contains solutions to exercises in Chapter 1: Sounds and Signals
Copyright 2015 Allen Downey
from __future__ import print_function, division
%matplotlib inline
import thinkdsp
import thinkplot
import warnings
warnings.filterwarnings('ignore')
from IPython.html.widgets import interact, fixed
from IPython.display import display
Go to http://freesound.org and download a sound sample that includes music, speech, or other sounds that have a well-defined pitch. Select a roughly half-second segment where the pitch is constant. Compute and plot the spectrum of the segment you selected. What connection can you make between the timbre of the sound and the harmonic structure you see in the spectrum?
Use high_pass, low_pass, and band_stop to
filter out some of the harmonics. Then convert the spectrum back
to a wave and listen to it. How does the sound relate to the
changes you made in the spectrum?
I chose this recording (or synthesis?) of a trumpet section http://www.freesound.org/people/Dublie/sounds/170255/
As always, thanks to the people who contributed these recordings!
wave = thinkdsp.read_wave("C:\\Users\\heine\\Desktop\\omio-babbino\\Jackie-Evancho-88sec.wav")
wave.normalize()
wave.make_audio()